package com.service;


import com.dao.DepDAO;
import com.dao.EmpDAO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.transaction.Transactional;
import java.util.List;

@Service
public class EmpService {

    @Autowired
    private EmpDAO empDAO;

    public List getAll() {
        return empDAO.findAll();
    }

    public List findByName(String name) {
        return empDAO.findByNameLike3(name+"%");
    }

}
